package com.lt.test.provider.mapper;

import com.lt.test.entity.DO.ShopDO;
import com.lt.test.entity.DTO.SuperMarketUserDTO;

import java.util.List;
import java.util.Map;

/**
 * 店铺相关
 * @author zhengchuan
 *
 */
public interface ShopMapper {
	/**
	 * 分页查询店铺信息
	 * @param pagequeryModel
	 * @return
	 * @throws Exception
	 */
	List<ShopDO> findShopByPage(Map<String, String> pagequeryModel) throws Exception;
	/**
	 * 查询shop总数
	 * @param pageQueryModel
	 * @return
	 */
	int getShopCount(Map<String, String> pageQueryModel);
	/**
	 * 编辑用户
	 * @param shop
	 * @throws Exception
	 */
	void editShopInfo(ShopDO shop) throws Exception;


	List<Map<String,Object>> findTenShipmentOrder(Map<String, String> params) throws Exception;

	List<Map<String,Object>> findShipmentOrderByLastOrderTime(Map<String, String> params) throws Exception;

	List<Map<String,Object>> findShipmentOrderDayData(Map<String, String> params) throws Exception;

	List<Map<String,Object>> findShipmentOrderMonthData(Map<String, String> params) throws Exception;

    List<Map<String,Object>> findShipmentOrderYearData(Map<String, String> params) throws Exception;


    List<Map<String,Object>> findTenScratchoff(Map<String, String> channelName)  throws Exception;

	List<Map<String,Object>> findScratchoffByLastOrderTime(Map<String, String> params)  throws Exception;

	List<Map<String,Object>> findScratchoffDayData(Map<String, String> params)  throws Exception;

	List<Map<String,Object>> findScratchoffMonthData(Map<String, String> params)  throws Exception;

	List<Map<String,Object>> findScratchoffWeekData(Map<String, String> params) throws Exception;

	/**
	 * 获取剩余物料
	 * @param params
	 * @return
	 * @throws Exception
	 */
	List<Map<String,Object>> findResidueScratchoff(Map<String, String> params) throws Exception;

	String getProductNameByTimeStr(Map<String, String> params) throws Exception;

    List<Map<String,Object>> getScratchoffByBeginTimeAndEndTime(Map<String, String> params) throws Exception;

    List<Map<String,Object>> getShipmentOrderByBeginTimeAndEndTime(Map<String, String> params) throws Exception;

    List<Map<String,Object>> selectStockByShopNameAndShopType(Map<String, String> params) throws Exception;

	List<Map<String,Object>> selectStockByShopNameAndShopTypes(Map<String, String> params) throws Exception;

    List<Map<String,Object>> exportKtTobaccoOrder(Map<String, String> params) throws Exception;

	List<Map<String,Object>> selectStockToExcel(Map<String, String> stringMap);

	int selectStockCountByShopNameAndShopType(Map<String, String> stringMap);

    List<Map<String,Object>> getShopNameToSelect(Map<String, String> params) throws Exception;

    List<Map<String,Object>> getPricesAndStockStatistics(Map<String, String> params) throws Exception;

	/**
	 * 获取商品最顶级的名称用来查询
	 * @return
	 * @throws Exception
	 */
    List<Map<String,String>> getProductFactoryName()  throws Exception;

	/**
	 * 获取商品第二级的名称用来查询
	 * @return
	 * @throws Exception
	 */
	List<Map<String,String>> getProductBandName()  throws Exception;

	/**
	 * 获取商品的名称用来查询
	 * @return
	 * @throws Exception
	 */
	List<Map<String,String>> getProductProductName()  throws Exception;

    SuperMarketUserDTO getShopAndUserByShopIdAndUserId(SuperMarketUserDTO user) throws Exception;

    Map<String,String> getOrderState(String orderId) throws Exception;

    //下面是综合统计

    String getSynthesis_registerNum(Map<String, String> stringMap) throws Exception;

	String getSynthesis_bindCarNum(Map<String, String> stringMap)throws Exception;

	String getSynthesis_expNum(Map<String, String> stringMap)throws Exception;

	String getSynthesis_dingYanNum(Map<String, String> stringMap)throws Exception;

	String getSynthesis_payNum(Map<String, String> stringMap)throws Exception;

	String getSynthesis_payCountNum(Map<String, String> stringMap)throws Exception;

	String getSynthesis_payAmt(Map<String, String> stringMap)throws Exception;

	String getSynthesis_orderQty(Map<String, String> stringMap);

	String getSynthesis_stockNum(Map<String, String> stringMap);

    List<Map<String,String>> getCustAnalyzeByPageQuery(Map<String, String> stringMap) throws Exception;

	int getCustAnalyzeCountByPageQuery(Map<String, String> stringMap) throws Exception;

	List<Map<String,String>> getProductAnalyzeByPageQuery(Map<String, String> stringMap);

	int getProductAnalyzeCountByPageQuery(Map<String, String> stringMap);


	List<Map<String,Object>> getStockAnalyzeCustExportExcelData(Map<String, String> stringMap);

	List<Map<String,Object>> getStockAnalyzeProductExportExcelData(Map<String, String> stringMap);

    List<Map<String,Object>> selectCustNameToSelected(Map<String, String> params);

	List<Map<String,Object>> getDaZhuanPanPrizeByPageQuery(Map<String, String> stringMap) throws Exception;

    List<Map<String,Object>> findShopToExportExcel(Map<String, String> params);

    Map<String,String> getHomePageProcess(Map<String, String> stringMap);

    Map<String,Object> getCustomerByFaceId(Map<String, Object> params);

	Map<String,Object> getCustomerBySysUserId(String customerId);

	List<Map<String,Object>> getBigScreenData(Map<String, Object> params);
}
